View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0001955 | T99X171.00 SKB Eagle | SW Issue | public | 2024-06-05 16:58 | 2024-12-19 10:52 |
| Reporter | (ALTech) JunGyu Kim | Assigned To | (SW) Kinbay Wu | Due Date | 2024-06-12 17:45 |
| Priority | normal | Severity | s4-minor | Reproducibility | always |
| Status | closed | Resolution | reopened | ||
| Summary | 0001955: [Smart3][ATV12] Zemkids app is not downgrade when FW downgrade | ||||
| Description | Hi Kinbay, Our QA found an issue that when FW downgrade, Zemkids app is not downgrade. [FW 15.542.48] dumpsys package com.skb.zemkids | grep version versionCode=358 minSdk=28 targetSdk=31 [FW 15.542.50] dumpsys package com.skb.zemkids | grep version versionCode=359 minSdk=28 targetSdk=31 In the case of the current UI, when FW downgrades, the UI version is also downgraded, so these routines must be set to zemkids in the same way. Please check the issue. Thank you. Kim | ||||
| Tags | No tags attached. | ||||
| Attach Tags | |||||
| User List |
|
|---|
|
|
Hi Kim Is the downgrade process by USB OTA? Include the keep_data? Best Regrads Kinbay |
|
|
Hi Kinbay, Yes, you can reproduce this issue by USB OTA include the keep data. Thank you. Kim |
|
|
Hi Kim Generally, the OTA upgrade or downgrade process does not automatically modify user-installed applications (third-party apps). If you force the app to wipe data (without keep_data), Zemkids will revert to version 358. Best Regards Kinbay |
|
|
Hi Kinbay zemkids is not a user-installed application. The zemkids app is a prebuilt app, but it was compressed for free space. (stub.apk) https://btracker-cns.fii-foxconn.com/vaas/view.php?id=1555 so this issue was observed If the compressed app at new FW is different from the installed version after FW update STB must uninstall the existing app(zemkids) and install a new version. Please check it Thank you YK.Jung |
|
|
Reminder sent to: |
|
|
Dear Kndbay This issue is set to BMT issue. so it is necessary to be fixed until tomorrow. ( because it is determined next software image ) === https://jira.skbroadband.com/browse/BPM-33466 please support this isssue ASAP. Thank you. Best Regards. |
|
|
Dear Kinbay Could you let me know when this issue can be fixed ? ( roughly schedule is okay as well ) Because this issue was changed to BMT issue yesterday, we don't have many time to apply patch for next release. I'm sorry for repeatedly request. Best Regards. |
|
|
Hi Jong-Hwa I will do my best. But I am not sure that can be fixed today. I found the log at PackageManager The pm(PackageManager) detects version 359 better than 358 so stuck in the process. I'm trying to skip version checking for the zemkids app --------------------- 05-09 20:57:44.389 3780 3810 I SystemConfig: Reading permissions from /system/etc/permissions/privapp-permissions-com.skb.zemkids.xml 05-09 20:57:45.414 3780 3780 I PackageManager: getCompressedFiles[/system/priv-app/SKB_ZemKids_SMART3_foxconn-Stub]: [/system/priv-app/SKB_ZemKids_SMART3_foxconn/SKB_ZemKids_SMART3_foxconn.apk.gz] 05-09 20:57:45.417 3780 3780 W PackageManager: Failed to scan /system/priv-app/SKB_ZemKids_SMART3_foxconn-Stub: Package com.skb.zemkids at /system/priv-app/SKB_ZemKids_SMART3_foxconn-Stub ignored: updated version 359 better than this 358 05-09 20:57:45.615 3780 3780 W PackageManager: Failed to parse /system/priv-app/SKB_ZemKids_SMART3_foxconn: Missing base APK in /system/priv-app/SKB_ZemKids_SMART3_foxconn 05-09 20:57:47.029 3780 3780 W PackageManager: Relax SCAN_REQUIRE_KNOWN requirement for package com.skb.zemkids 05-09 20:58:01.445 3780 3780 V StorageManagerService: Package com.skb.zemkids does not have legacy storage --------------------- Best Regards Kinbay |
|
|
Dear Kndbay I really appreciate your quick updates. Best Regards. JONGHWA/JUNG |
|
|
Hi Jong-Hwa I have resolved the problem with the attached patch. (path: frameworks/base/) If the Zemkids app is detected, it will skip the version comparison. Only check whether the version is different or not. Below is a log for reinstalling the app, please check. ----------------- 05-09 21:25:38.766 3779 3779 I PackageManager: getCompressedFiles[/system/priv-app/SKB_ZemKids_SMART3_foxconn-Stub]: [/system/priv-app/SKB_ZemKids_SMART3_foxconn/SKB_ZemKids_SMART3_foxconn.apk.gz] 05-09 21:25:38.767 3779 3779 W PackageManager: Detect com.skb.zemkids force reinstall the app 05-09 21:25:38.768 3779 3779 W PackageManager: System package updated; name: com.skb.zemkids; 359 --> 358; /data/app/~~Igb1libgOW8rwpDCg_Zjqg==/com.skb.zemkids-xp8JZl9x_-0U_h27cormIA== --> /system/priv-app/SKB_ZemKids_SMART3_foxconn-Stub 05-09 21:25:38.794 3779 3779 I PackageManager: /system/priv-app/SKB_ZemKids_SMART3_foxconn-Stub changed; collecting certs (forced) 05-09 21:25:38.801 3779 3779 I PackageManager: getCompressedFiles[/system/priv-app/SKB_ZemKids_SMART3_foxconn-Stub]: [/system/priv-app/SKB_ZemKids_SMART3_foxconn/SKB_ZemKids_SMART3_foxconn.apk.gz] 05-09 21:25:38.801 3779 3779 I PackageManager: Update system package com.skb.zemkids code path from /data/app/~~Igb1libgOW8rwpDCg_Zjqg==/com.skb.zemkids-xp8JZl9x_-0U_h27cormIA== to /system/priv-app/SKB_ZemKids_SMART3_foxconn-Stub; Retain data and using new ----------------- Best Regards Kinbay ZemKids_cannot_dwongrade.diff (1,317 bytes)
diff --git a/services/core/java/com/android/server/pm/PackageManagerService.java b/services/core/java/com/android/server/pm/PackageManagerService.java
index 17f6c41b3f8b..f149199ac3e0 100644
--- a/services/core/java/com/android/server/pm/PackageManagerService.java
+++ b/services/core/java/com/android/server/pm/PackageManagerService.java
@@ -12126,8 +12126,12 @@ public class PackageManagerService extends IPackageManager.Stub
final boolean newPkgChangedPaths = pkgAlreadyExists
&& !pkgSetting.getPathString().equals(parsedPackage.getPath());
+ final boolean zemkids_upgrade =
+ pkgAlreadyExists && pkgSetting.name.equals("com.skb.zemkids") && parsedPackage.getLongVersionCode() != pkgSetting.versionCode;
+ if (zemkids_upgrade)
+ Slog.w(TAG, "Detect "+ pkgSetting.name +" force reinstall the app");
final boolean newPkgVersionGreater =
- pkgAlreadyExists && parsedPackage.getLongVersionCode() > pkgSetting.versionCode;
+ pkgAlreadyExists && (parsedPackage.getLongVersionCode() > pkgSetting.versionCode || zemkids_upgrade);
final boolean isSystemPkgBetter = scanSystemPartition && isSystemPkgUpdated
&& newPkgChangedPaths && newPkgVersionGreater;
if (isSystemPkgBetter) {
|
|
|
Dear Kinbay We are applying your patch and testing this issue now. Almost test cases are passed but there is fail result for specific test case. BFX-AT100 has 2 source code tree both Sprint1 & 2. and app version is increased for each source code tree, but there is app which has same version & differnt revision between Sprint 1 & 2. So, it is necessary to compare revision information instead of version for this issue. Could you check we can use revision infromation for this issue ? Thank you. Best Regards |
|
|
Hi Jong-Hwa I am not clear what you mean by it. What is version & revision? Can you give an example? BTW, I can't see any branch name Sprint on framework/base or vendor/skb/prebuilts/digicap_zemkids Best Regards Kinbay |
|
|
Dear Knbay FYI, I describe specific fail case, fistly. I made test firmware(=15.542.6012 version) and this firmware is included your patch and it is base on Sprint1 source code branch. And there is 15.542.102 firmware, and it is base on Sprint2 source code tree. Unfortunatelly, two firmare's zemkids app use same versionCode, but it's revision is different. -> 15.542.6012 zamkids : versionCode 361, revision 8320 ( Sprint1 tree) -> 15.542.102 zamkids : versionCode 361, revision 8317 (Sprint2 tree) We only check versionCode, even if zamkids app is different each other, it is not updated. But it is very specific case, so we have discuss internally, it is better that we apply the patch now, and then if we met specific case error, we have solution later. Please commit this patch to repository. ( JIRA : BPM-33466, https://jira.skbroadband.com/browse/BPM-33466?filter=-3 ) I really appreciate your support. Best Regards. |
|
|
Hi Jong Hwa I just pushed the commit to UI542. For revision, the checker is determined in PackageManagerService. The service will impact security, so it is advisable not to change too much for security. Best Regards Kinbay |
|
|
Dear Kinbay We released new firmware with this patch, SKB tested & closed JIRA ticket. Thank you for support. Best Regards. |
|
|
This issue is closed. Thank you for support. JONGHWA/JUNG |
|
|
Hi Kinbay side effect of this patch is observed , it was reported to me yesterday evening , https://jira.skbroadband.com/browse/BPM-36880 issue is observed in the following cases. 1) Only update Zemkids app * Only Zemkids app can be updated through EDMP. (partial update) (ex) adb install -r zemkids_upper_version.apk zemkids Test app : http://altserver01.duckdns.org/release_by_ALT/BPM-36880/SKB_ZemKids_SMART3VCS_v1.542.0_vc371_r8371_foxconn_20240806.apk 2) rebooting 3) after rebooting , the Zemkids app return to the prebuilt version. * the EDMP updated version should be maintained. That is, after the FW update, it must be changed to the prebuilt Zemkids app but normal reboot, the Zemkids app version should not be changed. If there is a way to solve this, please share your ideas or contents. This issue should be resolved before 1 p.m. today. If you don't understand, please contact me. Please check it quickly. Thank you YK.Jung |
|
|
Hi YK, I attached the patch, which I added to the mIsUpgrade condition to fix the side effects. Please check it. BR, Kinbay 0001-BPM-36880-MT-1955-Fix-the-ZemKids-app-version-will-r.patch (1,618 bytes)
From acafe72f401d4ad0f1f8f5b8b52fff88274af63d Mon Sep 17 00:00:00 2001
From: Kinbay_Wu <kinbay.ty.wu@fii-foxconn.com>
Date: Fri, 6 Sep 2024 11:18:20 +0800
Subject: [PATCH] [BPM-36880] [MT-1955] Fix the ZemKids app version will reset
to the prebuilt version after reboot
Signed-off-by: Kinbay_Wu <kinbay.ty.wu@fii-foxconn.com>
---
.../java/com/android/server/pm/PackageManagerService.java | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/services/core/java/com/android/server/pm/PackageManagerService.java b/services/core/java/com/android/server/pm/PackageManagerService.java
index f149199ac3e0..fe40947c57da 100644
--- a/services/core/java/com/android/server/pm/PackageManagerService.java
+++ b/services/core/java/com/android/server/pm/PackageManagerService.java
@@ -12126,8 +12126,10 @@ public class PackageManagerService extends IPackageManager.Stub
final boolean newPkgChangedPaths = pkgAlreadyExists
&& !pkgSetting.getPathString().equals(parsedPackage.getPath());
- final boolean zemkids_upgrade =
- pkgAlreadyExists && pkgSetting.name.equals("com.skb.zemkids") && parsedPackage.getLongVersionCode() != pkgSetting.versionCode;
+ final boolean zemkids_upgrade = pkgAlreadyExists
+ && mIsUpgrade
+ && pkgSetting.name.equals("com.skb.zemkids")
+ && parsedPackage.getLongVersionCode() != pkgSetting.versionCode;
if (zemkids_upgrade)
Slog.w(TAG, "Detect "+ pkgSetting.name +" force reinstall the app");
final boolean newPkgVersionGreater =
--
2.25.1
|
|
|
Hi Kinbay Thank you for your support. First , I've checked the code and I'll give you feedback. Thank you YK.Jung |
|
|
Hi Kinbay The test result is OK. thank you for your quick support. Pleasse add BPM-36880 to the prefix message and push this patch to UI543 / UI542_CUG bitbucket. Please let me know when you're done. Thank you YK.Jung |
|
|
Hi YK, Pushed done. Please check it. BR, Kinbay |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2024-06-05 16:58 | (ALTech) JunGyu Kim | New Issue | |
| 2024-06-05 16:58 | (ALTech) JunGyu Kim | Status | new => assigned |
| 2024-06-05 16:58 | (ALTech) JunGyu Kim | Assigned To | => (SW) Kinbay Wu |
| 2024-06-05 16:58 | (ALTech) JunGyu Kim | Issue Monitored: (ALTech) SY Yoon | |
| 2024-06-05 16:58 | (ALTech) JunGyu Kim | Issue Monitored: (ALTech) Wooshin Kang | |
| 2024-06-05 16:58 | (ALTech) JunGyu Kim | Issue Monitored: (ALTech) Younkwang Jung | |
| 2024-06-05 16:59 | (ALTech) JunGyu Kim | Issue Monitored: (ALTech) Sangmin Choi | |
| 2024-06-05 17:38 | (SW) Kinbay Wu | Note Added: 0015960 | |
| 2024-06-05 17:55 | (ALTech) JunGyu Kim | Note Added: 0015961 | |
| 2024-06-06 10:19 | (SW) Kinbay Wu | Note Added: 0015963 | |
| 2024-06-06 10:20 | (SW) Kinbay Wu | Note Edited: 0015963 | |
| 2024-06-10 12:56 | (ALTech) Younkwang Jung | Note Added: 0015973 | |
| 2024-06-10 12:58 | (ALTech) Younkwang Jung | Issue Monitored: (ALTech) Jong-Hwa JUNG | |
| 2024-06-11 08:01 |
|
Note Added: 0015976 | |
| 2024-06-11 13:05 | (ALTech) Younkwang Jung | Due Date | 2024-06-14 17:45 => 2024-06-13 17:45 |
| 2024-06-11 13:09 |
|
Due Date | 2024-06-13 17:45 => 2024-06-12 17:45 |
| 2024-06-11 13:15 |
|
Note Added: 0015984 | |
| 2024-06-12 09:10 |
|
Note Added: 0015990 | |
| 2024-06-12 10:34 | (SW) Kinbay Wu | Note Added: 0015992 | |
| 2024-06-12 10:35 | (SW) Kinbay Wu | Note Edited: 0015992 | |
| 2024-06-12 11:42 |
|
Note Added: 0015994 | |
| 2024-06-12 18:39 | (SW) Kinbay Wu | Note Added: 0015999 | |
| 2024-06-12 18:39 | (SW) Kinbay Wu | File Added: ZemKids_cannot_dwongrade.diff | |
| 2024-06-12 18:40 | (SW) Kinbay Wu | Note Edited: 0015999 | |
| 2024-06-13 13:52 |
|
Note Added: 0016004 | |
| 2024-06-13 14:09 | (SW) Kinbay Wu | Note Added: 0016007 | |
| 2024-06-13 14:12 | (SW) Kinbay Wu | Note Edited: 0016007 | |
| 2024-06-13 16:31 |
|
Note Added: 0016019 | |
| 2024-06-13 16:57 | (SW) Kinbay Wu | Note Added: 0016022 | |
| 2024-06-24 09:32 |
|
Note Added: 0016085 | |
| 2024-06-24 09:33 |
|
Status | assigned => closed |
| 2024-06-24 09:33 |
|
Resolution | open => fixed |
| 2024-06-24 09:33 |
|
Note Added: 0016086 | |
| 2024-09-06 08:53 | (ALTech) Younkwang Jung | Status | closed => feedback |
| 2024-09-06 08:53 | (ALTech) Younkwang Jung | Resolution | fixed => reopened |
| 2024-09-06 08:53 | (ALTech) Younkwang Jung | Note Added: 0016676 | |
| 2024-09-06 11:24 | (SW) Kinbay Wu | Note Added: 0016677 | |
| 2024-09-06 11:24 | (SW) Kinbay Wu | File Added: 0001-BPM-36880-MT-1955-Fix-the-ZemKids-app-version-will-r.patch | |
| 2024-09-06 11:47 | (ALTech) Younkwang Jung | Note Added: 0016678 | |
| 2024-09-06 13:48 | (ALTech) Younkwang Jung | Note Added: 0016679 | |
| 2024-09-06 14:13 | (SW) Kinbay Wu | Note Added: 0016681 | |
| 2024-12-19 10:52 | (ALTech) JunGyu Kim | Status | feedback => closed |